import request from "@/utils/request";

// 查询核销商户列表
export function listShoper(query) {
  return request({
    url: "/cancel/shoper/list",
    method: "get",
    params: query,
  });
}

// 查询核销商户详细
export function getShoper(shId) {
  return request({
    url: "/cancel/shoper/" + shId,
    method: "get",
  });
}

// 新增核销商户
export function addShoper(data) {
  return request({
    url: "/cancel/shoper",
    method: "post",
    data: data,
  });
}

// 修改核销商户
export function updateShoper(data) {
  return request({
    url: "/cancel/shoper",
    method: "put",
    data: data,
  });
}

// 删除核销商户
export function delShoper(shId) {
  return request({
    url: "/cancel/shoper/" + shId,
    method: "delete",
  });
}
//是否启用
export function changeUpdateIsShelf(data) {
  return request({
    url: "/cancel/shoper/updateStatus",
    method: "put",
    data,
  });
}

export function showShoperList() {
  return request({
    url: "/cancel/shoper/parentList",
    method: "get",
  });
}
